<template>
	<!-- 一级客户我的账户 -->
	<view class="myaccount">
		<view class="myaccount-nav">
			<u-navbar title="账户明细" :background="background" title-color="#fff" back-icon-color="#fff">
			</u-navbar>
		</view>

		<view class="myaccount-con">
			<view>
				<!-- <view class="myaccount-con-li" v-for="(items,index) in customerList" :key='index'> -->
				<view class="myaccount-con-li">
					<!-- <view class="myaccountCon-name">郑州小石头</view> -->
					<view v-for="(item,index) in customerList" :key='index'>
					<view >
						<view class="myaccount-con-box">
							<view class="myaccountCon-cus-name">{{item.ORMTB410CA00}}</view>
							<view class='myaccountCon-Zdoll'>
								<view>
									<text>账户金额</text>
								</view>
								<view>
									<text v-if="zhengyan!=index">{{item.ORMTB410CA03}}元</text>
									<text v-if="zhengyan==index">****</text>
								</view>
							</view>
							<view class="myaccountCon-yukou">
								<view class="myaccountCon-yukouCon">
									<view @click="yukou">预扣金额 <text class="iconfont iconarrow_right"></text></view>
									<view class="myaccountCon-yukou-color">{{item.ORMTB410CA04}}元</view>
								</view>
								<view class="myaccountCon-yukouCon">
									<view>可用金额：</view>
									<view class="myaccountCon-keyong-color" v-if="zhengyan!=index">{{item.ORMTB410CA05}}元</view>
									<view v-if="zhengyan==index">****</view>
								</view>
							</view>
						</view>
					</view>


				</view>
				</view>
			</view>
		</view>
		<!-- <view class="zanWSJ" v-if="customerList.length==0">
			<image src="https://xstadmin.oss-cn-beijing.aliyuncs.com/HFcustomer/images/QXY/noData.png" mode="">
		</view> -->
	</view>
</template>

<script>
	export default {
		data() {
			return {
				background: {
					backgroundColor: '#00a1f1',
				},
				userinfo: JSON.parse(uni.getStorageSync('userinfo')),
				// systemInfo:uni.getSystemInfoSync(),
				navHeight:'' ,
				optionHeight:35,
				queryHeight:32,
				customerList: [],
			}
		},
		onShow(){
			var data=new Date()
			this.systemInfo=uni.getSystemInfoSync()
			this.navHeight=this.systemInfo.platform == 'ios' ? 64 : 68;
			this.getData()
		},
		methods: {
			getData() {
				uni.showLoading({
					title: '请求中...',
					mask: true
				});
				uni.request({
					url: this.baseUrl + '/orm/ormtb410/selectOrmtb410List',
					method: 'POST',
					dataType: 'json',
					data: {
						ORMTB400ID: this.userinfo.ORMTB400ID, //大客户ID
					},
					success: (res) => {
						console.log(res);
						if (res.data.code == 200) {
							this.customerList = res.data.data;
						} else {
							this.customerList = [];
							uni.showToast({
								title: res.data.message,
								duration: 5000,
								icon: 'none',
							});
						}
						uni.hideLoading();
					},
					fail: (res) => {
						uni.hideLoading();
						uni.showToast({
							title: res.data.message,
							duration: 5000,
							icon: 'none',
						});
					}
				});
			},
			// tobanlance(){
			// 	uni.navigateTo({
			// 		url: '../accountbalance/index'
			// 	})
			// },
			//充值
			rechargeClick() {
				uni.navigateTo({
					url: '../accountwithholding/index'
				})
			},
			rechargeDetails() {
				uni.navigateTo({
					url: '../accountbalance/index'
				})
			},
			customerDetails() {
				uni.navigateTo({
					url: '../accountwithholding/index'
				})
			},
			yukou() {
				uni.navigateTo({
					url: '../accountwithholding/index'
				})
			},
		}
	}
</script>

<style scoped>
	.slot-right-item{
		padding-right: 24rpx;
		color: #fff;
	}

	.myaccount {
		width: 100%;
		min-height: 100vh;
		padding-bottom: 100rpx;
		background-color: rgba(242, 242, 242, 1);
	}
	/* .quick-access-box::after {
		content: '';
		display: block;
		clear: both;
	} */
	.quick-access-box{
		display: flex;
		background-color: #fff;
	}
	.quick-access-box>view {
		width: 240rpx;
		height: 102rpx;
		/* float: left; */
		text-align: center;
		margin-bottom: 10rpx;
		vertical-align: middle;
	}
	.iconchongzhi1{
		color: #FCAA1A;
		font-size: 54rpx;
	}
	.iconzhanghu1{
		color: #00A1F1;
		font-size: 62rpx;
	}
	.iconwode1{
		color: #02B277;
		font-size: 60rpx;
	}

	.myaccount-conditions {
		display: flex;
		background-color: #FFF;
		color: #333;
		font-size: 30rpx;
		line-height: 44rpx;
		padding: 15rpx 21rpx;
		height: 84rpx;
		overflow: hidden;
		border-bottom: 12rpx solid rgba(242, 242, 242, 1);
	}

	.myaccount-conditions-tab {
		flex: 1;
		text-align: center;
		font-size: 30rpx;
		font-weight: 500;
		overflow: hidden;
		position: relative;
		padding-right: 36rpx;
		color: #333;
	}

	.myaccount-conditions-tab-border {
		border-left: 4rpx solid #f2f2f2;
	}

	.myaccount-conditions-tab+.myaccount-conditions-tab {
		margin-left: 22rpx;
	}

	.myaccount-conditions-tab text {
		position: absolute;
		right: 0;
	}

	.myaccount-conditions-tab .iconfont {
		font-size: 30rpx;
		color: #99989b;
		margin-left: 7rpx;
	}

	.myaccount-nav {
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		z-index: 222;
		/* background: rgba(255, 255, 255, 1); */
	}






	.myaccount-con {
		margin-top: 160rpx;
	}

	.myaccount-con .myaccount-con-li {
		width: 100%;
		/* background: rgba(255, 255, 255, 1); */
		/* height: 10px; */
		margin-top: 7rpx;
		/* padding: 0 0.49rem;
	  padding-top: 0.42rem; */
		/* padding-bottom: 0.56rem; */
	}

	.myaccount-con .myaccount-con-li:first-child {
		margin-top: 0;
	}

	.myaccountCon-Zdoll {
		width: 100%;
		display: flex;
		justify-content: space-between;
	}

	.myaccountCon-yukou-color {
		font-size: 36rpx !important;
		color: rgba(255, 53, 53, 1) !important;
	}

	.myaccountCon-keyong-color {
		font-size: 36rpx !important;
		color: rgba(51, 51, 51, 1) !important;
	}

	.myaccountCon-name {
		padding: 15rpx 35rpx;
		background: rgba(255, 255, 255, 1);
		font-size: 28rpx;
		color: rgba(0, 161, 241, 1);
		overflow: hidden;
	}

	.myaccount-con-box {
		background: rgba(255, 255, 255, 1);
		padding: 0 35rpx;
		padding-top: 30rpx;
		padding-bottom: 40rpx;
		margin-top: 7rpx;
	}

	.myaccountCon-cus-name {
		font-size: 26rpx;
		color: #333;
		margin-bottom: 15rpx;
		padding-bottom: 15rpx;
		/* padding-left: 35rpx; */
		overflow: hidden;
		border-bottom: 2rpx solid #F0F0F0;

	}

	.myaccountCon-Zdoll view:first-child {
		font-size: 26rpx;
		color: rgba(51, 51, 51, 1);
	}

	.myaccountCon-Zdoll .iconzhengyan,
	.myaccountCon-Zdoll .iconbiyan {
		display: inline-block;
		width: 144rpx;
		/* background-color: #000000; */
		font-size: 28rpx;
		color: rgba(153, 153, 153, 1);
	}

	.myaccountCon-Zdoll view:last-child {
		font-size: 36rpx;
		color: rgba(51, 51, 51, 1);
	}

	.myaccountCon-yukou {
		width: 100%;
		/* display: flex; */
		justify-content: space-between;
		margin-top: 29rpx;
		position: relative;
	}

	.shuxian {
		position: absolute;
		left: 47%;
		top: 11%;
		width: 4rpx;
		height: 30rpx;
		background: rgba(153, 153, 153, 1);
	}

	.myaccountCon-yukouCon {
		display: flex;
		justify-content: space-between;
		font-size: 26rpx;
	}

	.myaccountCon-yukouCon+.myaccountCon-yukouCon {
		margin-top: 15rpx;
	}

	.myaccountCon-yukouCon text {
		font-size: 22rpx;
		/* margin-left: -0.05rem; */
	}

	.myaccountCon-yukouCon view:first-child {
		color: rgba(102, 102, 102, 1);
	}

	/* 缺省页 */
	.myaccount .zanWSJ {
		padding-top: 200rpx;
	}

	.myaccount .zanWSJ image {
		display: block;
		margin: 0 auto;
		height: 360rpx;
		width: 43%;
	}
</style>
